import request from '@/utils/request'
/**
 * 上传图片
 * @param data
 */
export function upload(data: any) {
  return request({
    url: `/v2/upload/upload.json`,
    method: 'post',
    data
  })
}
/**
 * 获取上传图片地址
 * @param data
 */
export function getImg(key: string) {
  return request({
    url: `/v2/upload/access_url.json?key=${key}`,
    method: 'get',
  })
}
